import React from "react";
import { View } from "react-native";
import ChatSetting from "@/components/Settings/Chat";
import { Stack } from "expo-router";

import { getHeaderStyle } from "@/styles/header.style";
import { useTheme } from "@/contexts/ThemeContext";

export default function ChatSettingPage() {
  // 获取当前主题模式
  const { themeMode } = useTheme();
  // 获取基于当前主题的header样式
  const headerStyles = getHeaderStyle(themeMode);

  return (
    <>
      <Stack.Screen
        options={{
          title: "聊天设置",
          headerTitleAlign: headerStyles.headerTitleAlign as "left" | "center",
          headerStyle: headerStyles.headerStyle,
          headerTintColor: headerStyles.headerTintColor,
          headerTitleStyle: headerStyles.headerTitleStyle,
        }}
      />
      <View>
        <ChatSetting />
      </View>
    </>
  );
}
